import { BaseApi } from '/@/api-services/apis/baseApi';
import { SysDictData, DictDataUpdateInput, DictDataAddInput } from '../../models/system'

/**
 * 字典数据Api
 */
class SysDictDataApi extends BaseApi<SysDictData, DictDataAddInput, DictDataUpdateInput> {

   getDatalistByType=async(category:string)=>{
      return this.normalGet<Array<SysDictData>>(`/listByType`,{'category':category})
   }
   getDatalistByTypeId=async(id:number)=>{
      return this.normalGet<Array<SysDictData>>(`/listByTypeId`,{'dictTypeId':id})
   }
}

export default new SysDictDataApi('/system/dictData');